#include<cstdio>
#include<algorithm>
using namespace std;
int bin[100010];
int main()
{
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    int n,r;
    scanf("%d",&n);
    for(int i=0;i<n;i++)
    {
        scanf("%d",&r);
        bin[r]++;
    }
    int ans=0;
    for(int i=0;i<100005;i++)
    {
        ans=max(0,ans-bin[i]);
        ans+=bin[i];
    }
    printf("%d",ans);
    return 0;
}
